<form
  action=""
  method="post"
  enctype="multipart/form-data"
  name="register"
  id="registerId">

action => location of web where we have to submit form

method => The way in which we want to submit form (GET or POST)

enctype => If we want to upload images or files then we need to keep this attribute

name => Name of element for identification

Id => Id of element as It is Unique on web page
</form>

Event On form :-

Ques : What you will do if you need to perform
some validation before submission of form ?
Ans : use Event onSubmit() on <form>

<form onSubmit="validateForm(this)">

</form>

In above form validateForm() function will be call when user submit the form with submit button.

validateForm() function should be in Javascript like

<script type="text/javascript">
  function validateForm(obj){
    // do some check
    return true;
  }
</script>


